
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<%--
  Created by IntelliJ IDEA.
  User: evans
  Date: 2018/3/15
  Time: 下午5:37
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<!doctype html>
<html lang="en">
<head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width,initial-scale=1,shrink-to-fit=no" />
    <meta name="theme-color" content="#000000" />
    <title>Soico</title>
    <link rel="stylesheet" href="../../css/main.827f7436.css" />
    <link rel="stylesheet" href="../../css/materialize.min.css" />
    <link rel="stylesheet" href="../../css/App.css">
    <link rel="stylesheet" href="../../css/Header.css">
    <script type="text/javascript" async="" src="../../js/common/recaptcha__zh_cn.js"></script>
    <script type="text/javascript" src="../../js/common/jquery-3.3.1.min.js"></script>
    <script type="text/javascript" src="../../js/common/materialize.min.js"></script>
    <script type="text/javascript" >
        function searchProject(){
            var keyWord = $('#keyWord').val();
            window.location.href="http://www.soico.co/projectsSkip?name="+keyWord;
        }
    </script>
</head>
<body>
<div id="root">
    <div style="background-color: rgb(250, 250, 250); min-height: 100vh; min-width: 1000px; font-family: &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;">
        <div>
            <div class="s-alert-wrapper"></div>
            <%@include file="top.jsp"%>
            <div class="container">
                <div class="projectList">
                    <div class="row" style="margin-bottom: 0px;">
                        <h5 style="font-size: 1.2em;">进行中的项目</h5>
                        <div class="col s8">
                            <div class="row" style="margin-bottom: 0px;">
                                <div class="col input-field s7">
                                    <input  id="keyWord" type="text" class="validate" id="input_0" />
                                    <%--<label class="" for="input_0">项目关键字</label>--%>
                                </div>
                                <div class="col s5">
                                    <button class="btn waves-effect waves-light" style="margin-top: 20px; font-size: 0.7em; display: block;" onclick="searchProject()">搜索</button>
                                </div>
                            </div>
                        </div>
                        <div class="col s4">
                            <div style="vertical-align: middle; line-height: 80px; text-align: center; font-size: 0.9em;">
                                <div class="rox w">
                                    <div class="col s6">
                                        <a href="projectsSkip?status=0">进行中(${running})</a>
                                    </div>
                                    <div class="col s6">
                                        <a href="projectsSkip?status=1">已结束(${stop})</a>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                    <div class="row">
                        <c:forEach items="${projects}" var="project">
                        <div class="col s12">
                            <a href="projectsDetailSkip?pk=${project.pk}">
                            <div class="ProjectCell Bigcell" style="border: 1px solid rgb(186, 184, 184);">
                                <div class="row" style="margin-bottom: 0px;">
                                    <div class="col s6" style="display: table-cell;">
                                        <img class="projectBigImage" src="images/${project.project_name}.png" />
                                    </div>
                                    <div class="col s6">
                                        <p style="font-size: 1.2em; font-weight: bold;">${project.project_name}</p>
                                        <div style="min-height: 20px; display: flex; align-items: center;">
                                            <img src="images/${project.project_name}.png" style="width: 20px; height: 20px;" />
                                            <p style="display: inline; margin-left: 10px; line-height: 0; font-size: 10px;">${project.project_name}</p>
                                        </div>
                                        <div class="LinesEllipsis  max-lines">
                                        </div>
                                        <div style="font-size: 0.7em;">
                                            <p>已募集 :<c:choose>
                                                <c:when test="${project.project_status== '1'}">
                                                    ${project.simple_info}
                                                </c:when>
                                                <c:otherwise>
                                                    ${project.amount} ETH
                                                </c:otherwise>
                                            </c:choose></p>
                                            <p>开始时间 : <fmt:formatDate value="${project.ico_start}" pattern="yyyy-MM-dd"/></p>
                                            <p>结束时间 : <fmt:formatDate value="${project.ico_end}" pattern="yyyy-MM-dd"/></p>
                                        </div>
                                    </div>
                                </div>
                            </div>
                            </a>
                        </div>
                        </c:forEach>
                    </div>
                    <ul class="pagination">
                        <li class="waves-effect disabled"><a><i class="material-icons">chevron_left</i></a></li>
                        <li class="waves-effect active"><a>1</a></li>
                        <li class="waves-effect disabled"><a><i class="material-icons">chevron_right</i></a></li>
                    </ul>
                </div>
            </div>
            <footer class="page-footer">
                <%@include file="footer.jsp"%>
            </footer>
        </div>
    </div>
</div>
</body>
</html>